﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Linq.Expressions;

namespace CH.Study.ConsoleApp.ExpressionTree
{
    public class QueryContext
    {
        private ConnectionType connectionType;
        private QueryExpressionProvider provider;
        public QueryContext()
        {
            this.connectionType = ConnectionType.MsSql;
            switch (this.connectionType)
            {
                case ConnectionType.MsSql:
                    provider = new MsSqlQueryProvider();
                    break;
                case ConnectionType.Access:
                    break;
                default:
                    break;
            }
        }
        public QueryQueryable<T> Table<T>()
        {
            return new QueryQueryable<T>(provider);
        }



    }
}
